<!doctype html>
<html class="no-js " lang="en">
<head>
<meta charset="utf-8">

    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <title>默笙后台管理系统</title>
    <link rel="icon" type="image/ico" href="{$Think.const.SET_URL}/assets/images/favicon.ico" />
    <meta name="description" content="">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="stylesheet" href="{$Think.const.SET_URL}/assets/js/vendor/bootstrap/bootstrap.min.css">
    <link rel="stylesheet" href="{$Think.const.SET_URL}/assets/css/vendor/animsition.min.css">
    <link rel="stylesheet" href="{$Think.const.SET_URL}/assets/js/vendor/colorpicker/css/bootstrap-colorpicker.min.css">
    <link rel="stylesheet" href="{$Think.const.SET_URL}/assets/js/vendor/touchspin/jquery.bootstrap-touchspin.min.css">
    <link rel="stylesheet" href="{$Think.const.SET_URL}/assets/js/vendor/chosen/chosen.css">    
    <link rel="stylesheet" href="{$Think.const.SET_URL}/assets/css/main.css">
</head>

<body id="falcon" class="main_Wrapper">
    <div id="wrap" class="animsition">
        <!-- 头部 -->
        <div id="header">
            <header class="clearfix">
                <!-- Logo -->
                <div class="branding">
                    <a class="brand" href="index.html">
                        <span>默笙</span>
                    </a>
                    <a role="button" tabindex="0" class="offcanvas-toggle visible-xs-inline">
                        <i class="fa fa-bars"></i>
                    </a>
                </div>
                <!-- logo end -->

                <!-- 左侧导航 -->
                <ul class="nav-left pull-left list-unstyled list-inline">
                    <li class="leftmenu-collapse">
                        <a role="button" tabindex="0" class="collapse-leftmenu">
                            <i class="fa fa-outdent"></i>
                        </a>
                    </li>
                    <li class="dropdown leftmenu-collapse">
                        <a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown">
                            <i class="fa fa-language"></i>
                        </a>
                        <div class="dropdown-menu pull-left panel-default pt-0 pb-0" role="menu">
                            <ul class="list-group mb-0">
                                <li class="list-group-item">
                                    <a href="javascript:void(0);" class="p-0 m-0" >中文</a>
                                </li>
                                <li class="list-group-item">
                                    <a href="javascript:void(0);" class="p-0 m-0" >中文</a>
                                </li>
                                <li class="list-group-item">
                                    <a href="javascript:void(0);" class="p-0 m-0" >中文</a>
                                </li>
                                <li class="list-group-item">
                                    <a href="javascript:void(0);" class="p-0 m-0" >中文</a>
                                </li>
                            </ul>
                        </div>
                    </li>
                    
                </ul>
                <!-- 左侧导航 end -->
                <div class="search" id="main-search">
                    <input type="text" class="form-control underline-input" placeholder="输入内容来搜索">
                </div>
                <!-- 搜索结束 end -->

                <!-- Right-side navigation -->
                <ul class="nav-right pull-right list-inline">
                    
                   
                    <li class="dropdown notifications">
                        <a href="{:U('index/LoginOut')}" class="dropdown-toggle" >
                            <i class="fa fa-sign-out"></i>
                            <div class="notify">
                                <span class="heartbit"></span>
                                <span class="point"></span>
                            </div>
                        </a>
                        
                    </li>
                </ul>
                <!-- Right-side navigation end -->
            </header>
        </div>
        <!--/ 头部结束  -->
        <!-- CONTROLS Content  -->
        <div id="controls">
            <aside id="leftmenu">
                <div id="leftmenu-wrap">
                    <div class="panel-group slim-scroll" role="tablist">
                        <div class="panel panel-default">
                            <div id="leftmenuNav" class="panel-collapse collapse in" role="tabpanel">
                                <div class="panel-body">
                                    <!--  导航内容 -->
                                    <ul id="navigation">
                                        <li >
                                            <a href="{:U('index/index')}">
                                                <i class="fa fa-dashboard"></i>
                                                <span>仪表盘</span>
                                            </a>
                                        </li>
                                        
                                        <li>
                                            <a href="{:U('index/insta')}">
                                                <i class="fa fa-cogs"></i>
                                                <span>接口状态管理</span>
                                            </a>
                                        </li>
                                        <li class="active open">
                                            <a role="button" tabindex="0">
                                                 <i class="fa fa-delicious"></i>
                                                <span>用户管理</span>
                                            </a>
                                            <ul>
                                                <li>
                                                    <a href="{:U('user/index')}">
                                                        <i class="fa fa-angle-right"></i>用户列表</a>
                                                </li>
                                                <li class="active">
                                                    <a href="{:U('user/addkami')}">
                                                        <i class="fa fa-angle-right"></i>卡密生成</a>
                                                </li>
                                                <li >
                                                    <a href="{:U('user/kmlist')}">
                                                        <i class="fa fa-angle-right"></i>卡密列表</a>
                                                </li>
                                            </ul>
                                        </li>
                                        
                                        <li>
                                            <a role="button" tabindex="0">
                                                <i class="fa fa-lock"></i>
                                                <span>系统设置</span>
                                            </a>
                                            <ul>
                                                <li>
                                                    <a href="{:U('system/index')}">
                                                        <i class="fa fa-angle-right"></i>修改密码</a>
                                                </li>
                                                <li>
                                                    <a href="{:U('system/loginep')}">
                                                        <i class="fa fa-angle-right"></i>基本设置</a>
                                                </li>
                                                
                                            </ul>
                                        </li>
                                        <li>
                                            
                                            <a href="{:U('index/LoginOut')}">
                                                <i class="fa fa-sign-out"></i>
                                                <span>退出登陆</span>
                                            </a>
                                            
                                        </li>
                                    </ul>
                                    <!--/ 导航结束 -->
                                </div>
                            </div>
                        </div>
                        <div class="panel settings panel-default">
                            <div class="panel-heading" role="tab">
                                <h4 class="panel-title">
                                    <a data-toggle="collapse" href="#leftmenuControls">设置
                                        <i class="fa fa-angle-up"></i>
                                    </a>
                                </h4>
                            </div>
                            <div id="leftmenuControls" class="panel-collapse collapse in" role="tabpanel">
                                <div class="panel-body">
                                    <div class="form-group">
                                        <div class="row">
                                            <label class="col-xs-8">打开</label>
                                            <div class="col-xs-4 control-label">
                                                <div class="togglebutton">
                                                    <label>
                                                        <input type="checkbox" checked="">
                                                    </label>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="form-group">
                                        <div class="row">
                                            <label class="col-xs-8">关闭</label>
                                            <div class="col-xs-4 control-label">
                                                <div class="togglebutton">
                                                    <label>
                                                        <input type="checkbox">
                                                    </label>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="milestone-sidbar">
                                <div class="text-center-folded">
                                    <span class="pull-right pull-none-folded">60%</span>
                                    <span class="hidden-folded">CPU</span>
                                </div>
                                <div class="progress progress-xxs m-t-sm dk">
                                    <div class="progress-bar progress-bar-info" style="width: 60%;"> </div>
                                </div>
                                <div class="text-center-folded">
                                    <span class="pull-right pull-none-folded">35%</span>
                                    <span class="hidden-folded">内存</span>
                                </div>
                                <div class="progress progress-xxs m-t-sm dk">
                                    <div class="progress-bar progress-bar-primary" style="width: 35%;"> </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </aside>
            
        </div>
        <!--/ CONTROLS Content -->
        <!--  CONTENT  -->
        <section id="content">
            <div class="page page-forms-common">
                <!-- bradcome -->
                <div class="b-b mb-10">
                    <div class="row">
                        <div class="col-sm-6 col-xs-12">
                            <h1 class="h3 m-0">卡密生成</h1>
                            <small class="text-muted">欢迎使用默笙后台管理系统 </small>
                        </div>
                    </div>
                </div>
                <!-- 修改版权死妈！by：默笙 QQ：3494490 -->
                <!-- row -->
                <div class="row">
                    <div class="col-md-12">
                        
                        <section class="boxs">
                            <div class="boxs-header">
                                <h3 class="custom-font hb-blush">
                                    <strong>卡密生成</strong> </h3>

                            </div>
                            <div class="boxs-body">
                                <div class="form-horizontal" role="form">
                                    <div class="form-group">
                                        <label for="input01" class="col-sm-2 control-label">生成数量</label>
                                        <div class="col-sm-10">
                                            <input type="text" value="" class="form-control" id="count">
                                        </div>
                                    </div>
                                    
                                    
                                    <hr class="line-dashed full-witdh-line" />
                                    
                                    <div class="form-group">
                                        <label class="col-sm-2 control-label"><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">卡密方式</font></font></label>
                                        <div class="col-sm-10">
                                            <select tabindex="3" id="status" class="chosen-select" style="width: 240px;">
                                               
                                                    <option value="1"><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">月卡</font></font></option>
                                                    <option value="2"><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">年卡</font></font></option>
                                                
                                               
                                            </select>
                                        </div>
                                    </div>
                                    
                                    <hr class="line-dashed full-witdh-line" />
                                    <div class="form-group">
                                        <div class="col-sm-4 col-sm-offset-2">
                                            <button id="sub" class="btn btn-raised btn-danger">提交</button>
                                            <a href="{:U('user/index')}" class="btn btn-raised btn-default">返回</a>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </section>
                    </div>
                </div>
            </div>
        </section>
        <!--/ CONTENT -->
    </div>
    <!--/ Application Content -->
    <!--Vendor JavaScripts  -->
    <script src="{$Think.const.SET_URL}/assets/bundles/libscripts.bundle.js"></script>
    <script src="{$Think.const.SET_URL}/assets/bundles/vendorscripts.bundle.js"></script>

    
    <script src="{$Think.const.SET_URL}/assets/js/vendor/touchspin/jquery.bootstrap-touchspin.min.js"></script> 
    
    <script src="{$Think.const.SET_URL}/assets/js/vendor/chosen/chosen.jquery.min.js"></script> 
    <script src="{$Think.const.SET_URL}/assets/js/vendor/filestyle/bootstrap-filestyle.min.js"></script> 
    
    <script src="{$Think.const.SET_URL}/assets/layer.js"></script>
    <!--/ vendor javascripts -->
    <script src="{$Think.const.SET_URL}/assets/js/moment-with-locales.js"></script>
    <script src="{$Think.const.SET_URL}/assets/js/bootstrap-datetimepicker.js"></script>
    <!--  Custom JavaScripts -->
    <script src="{$Think.const.SET_URL}/assets/bundles/mainscripts.bundle.js"></script>
    
    
<!--/ Page Specific Scripts --> 
    <script type="text/javascript">
    $("#sub").click(function () {

        var e = 0;
        var count = $("#count").val();
        
        var sta = document.getElementById("status").value;

        if (count == "") {
            layer.msg('请输入生成的数量', function () {
                //关闭后的操作
                return false;
            });
            return false;
        }
        if (e == 0) {
            $.post("{:U('user/addkami')}", { count: count, sta:sta}, function (data) {
                if (data.status == '1') {
                    layer.alert(data.info, { icon: 6 });//layer.msg('不开心。。', {icon: 5});
                    window.location.href = data.url;
                } else {
                    layer.alert(data.info, { icon: 5 });
                }
            })
        }

    })
</script>

</body>
</html>